package com.lightsaber.trade.core.dao.sysparam;

import java.util.List;

import org.springframework.stereotype.Component;

import com.lightsaber.trade.core.dao.BaseDao;
import com.lightsaber.trade.core.entity.sysparam.SysParamete;

@Component
public class SysParameteDao extends BaseDao<SysParamete, String> {

    public SysParamete findByTypeAndCode(String type, String code) {
        eq("type", type);
        eq("code", code);

        return unique();
    }

    public List<SysParamete> findByType(String type) {
        eq("type", type);

        return list();
    }
}
